본문 바로가기
오류 노트

[오류 해결] This version (1.2.0) of the Compose Compiler requires Kotlin version 1.7.0 오류

by Echung 2023. 12. 15.

오류 내용


안드로이드 스튜디오를 통해 개발을 진행하던 중 오류가 발생하였습니다.

  • This version (1.2.0) of the Compose Compiler requires Kotlin version 1.7.0 but you appear to be using Kotlin version 1.9.0 which is not known to be compatible.  Please fix your configuration (or `suppressKotlinVersionCompatibilityCheck` but don't say I didn't warn you!).

사진 1. 오류 내용

위의 문제가 발생하는 이유는 Kotlin버전과 Compose 컴파일러 버전이 달라서 생기는 오류입니다. 

오류 해결 방법


사진 2. 코틀린 버전별 컴파일러 버전

위의 표를 보면 저는 Kotlin 1.9.0으로 사용할 예쩡이니 Compiler버전은 1.5.2를 사용하면 됩니다.

다음부터는 Kotlin을 변경할 때는 Compiler버전을 같이 수정하는 것을 항상 생각하면서 개발을 진행해야겠습니다.

Reference


https://developer.android.com/jetpack/androidx/releases/compose-kotlin

반응형